package cn.edu.sgu.www.mhxysy.dto.chongwu;

import cn.edu.sgu.www.mhxysy.consts.CustomMessages;
import cn.edu.sgu.www.mhxysy.consts.RegExps;
import cn.edu.sgu.www.mhxysy.dto.DataTransferObject;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Positive;

/**
 * @author 沐雨橙风ιε
 * @version 1.0
 */
@Data
@ApiModel
public class ChongwuSkillDTO implements DataTransferObject {

	@ApiModelProperty(value = "ID")
	private String id;

	/**
	 * 宠物技能类型ID
	 */
	@Positive(message = "宠物技能类型ID" + CustomMessages.ILLEGAL)
	@NotNull(message = "宠物技能类型" + CustomMessages.ID_NOT_NULL)
	@ApiModelProperty(value = "宠物技能类型ID", required = true)
	private Integer skillId;

	/**
	 * 宠物ID
	 */
	@Pattern(regexp = RegExps.CHONGWU_ID, message = "宠物ID" + CustomMessages.ILLEGAL)
	@NotBlank(message = CustomMessages.CHONGWU_ID_NOT_NULL)
	@ApiModelProperty(value = "宠物ID", required = true)
	private String chongwuId;

	/**
	 * 技能位置
	 */
	@Range(min = 1, max = 13, message = "技能位置" + CustomMessages.ILLEGAL)
	@NotNull(message = "技能位置" + CustomMessages.NOT_NULL)
	@ApiModelProperty(value = "技能位置", required = true)
	private Integer location;

	/**
	 * 认证状态
	 */
	@Range(min = 0, max = 1, message = "认证状态" + CustomMessages.ILLEGAL)
	@NotNull(message = "认证状态" + CustomMessages.NOT_NULL)
	@ApiModelProperty(value = "认证状态", required = true)
	private Integer authStatus;
}